<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>

</head>
<body>

<div id="app">

		<div v-if="role == 'admin' || role == 'super-admin'">
			管理员你好！
		</div>
		<div v-else-if="role == 'hr'">
			待查看简历列表：
		</div>
		<div v-else>
			您没有权限访问此页面
		</div>
			

	

		<hr>
		<h4>以上是vue if else if的用法</h4>
		<br>
				

		<table border="1">
			<thead>
				<th>学科</th>
				<th>分数</th>
			</thead>
			<tbody>
				<tr>
					<td>数学</td>
					<td><input type="text" v-model.number="math"></td>
				</tr>
				<tr>
					<td>物理</td>
					<td><input type="text" v-model.number="physics"></td>
				</tr>
				<tr>
					<td>英语</td>
					<td><input type="text" v-model.number="english"></td>
				</tr>
				<tr>
					<td>总分</td>
					<!--td>{{ math + physics + english }}</td-->
					<td>{{sum}}</td>
				</tr>
				<tr>
					<td>平均分</td>
					<!--td>{{ Math.round((math + physics + english)/3) }}</td-->
					<td>{{average}}</td>
				</tr>
			</tbody>
		</table>
				

		<hr>
		<h4>以上是vue 计算修饰符  computed 的用法</h4>
		<br>

</div>
<script type="text/javascript" src="vue.min.js"></script>
<script type="text/javascript" src="main.js"></script>
</body>
</html>